package demo.practice.dp;

public class P334 {


    public boolean increasingTriplet(int[] nums) {


        int min= Integer.MAX_VALUE;
        int mid= Integer.MAX_VALUE;

        for(int n : nums){
            if(n<min){
                min=n;
            }else if(n>min&& n< mid ){
                mid=n;
            }else if(n>mid){
                return true;
            }
        }

        return false;
    }
}
